#!/bin/sh


alert --warning 	"Install unrar, edit your expander.rules to have Expander support RAR archives, and register the 'application/x-rar' MIME type?" \
			"No way." "Sure" || \
			
			(
			echo $DIRECTORY;
			cp unrar /boot/home/config/bin/ ;
			mimeset -f /boot/home/config/bin/unrar ;
			echo  >> /boot/home/config/etc/expander.rules
			echo "application/x-rar"	.rar	"unrar l %s"		"unrar x -y %s" >> /boot/home/config/etc/expander.rules ;
			setmime -set application/x-rar -short "RAR Archive" -long "RAR compressed file." -preferredAppSig application/x-vnd.Be-EXPD -extension rar -extension RAR ;
			alert --info "Have fun." "Sweetness."
			)
